package com.jcl.recruit.timer.resume;

import com.jcl.recruit.timer.resume.service.SearchResumeTaskService;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

/**
 * @author 刘明新
 * @date 2018/8/31 上午11:34
 */
@Component
public class SearchResumeTask {

    private static final Logger log = LoggerFactory.getLogger(SearchResumeTask.class);

    @Autowired
    private SearchResumeTaskService searchResumeTaskService;

    /**
     * 每天12点清空推荐表的爬虫拉取记录
     */
    @Scheduled(cron = "0 0 * * * ?")
    public void searchResumeTaskFlush(){

        searchResumeTaskService.searchResumeFlushTask();

    }

}
